package Collection.List;

import org.apache.poi.ss.formula.functions.T;

import java.util.ArrayList;

public class GenericList {
    public static void main(String[] args) {
        //不声明 类型 即为 Object
        ArrayList list = new ArrayList();
        list.add("张三");
        list.add(123);
        char a = 'a';
        list.add(a);
        for(Object s : list){
            System.out.println( s.getClass());
        }

        System.out.println("----------------------");
        
    }
}
